package com.itbaizhan.domain;

import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;
/*在Spring中使用MyBatisPlus。*/
@Data
@NoArgsConstructor
@AllArgsConstructor
public class Student {
    private Integer id;
    private String name;
    private String email;
    private String gender;
    private Integer age;
}
/*在Mysql中准备数据：
* DROP DATABASE IF EXISTS `school`;
CREATE DATABASE `school`;
USE `school`;

DROP TABLE IF EXISTS `student`;
CREATE TABLE `student` (
 `id` int(11) NOT NULL AUTO_INCREMENT,
 `name` varchar(255) DEFAULT NULL,
 `email` varchar(255) DEFAULT NULL,
    `gender` varchar(255) DEFAULT NULL,
 `age` int(11) DEFAULT NULL,
 PRIMARY KEY (`id`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4;

INSERT INTO `student` VALUES ('1', '百战', 'bz@itbaizhan.com', 'm', '22');
INSERT INTO `student` VALUES ('2', '尚学堂', 'sxt@itbaizhan.com', 'f', '25');
INSERT INTO `student` VALUES ('3', '小张', 'zhang@itbaizhan.com', 'm', '30');
INSERT INTO `student` VALUES ('4', '小王', 'wang@itbaizhan.com', 'f', '35');
INSERT INTO `student` VALUES ('5', '小李', 'li@itbaizhan.com', 'm', '32');
INSERT INTO `student` VALUES ('6', '小赵', 'zhao@itbaizhan.com', 'm', '32');*/